package Chapter01.Homework.Work05;

import java.util.HashMap;
import java.util.Map;
import java.util.Scanner;

public class Work05 {
    public static void main(String[] args) {
        Scanner input=new Scanner(System.in);
        System.out.println("请输入值：");
        Map map=new HashMap();
        map.put("Dog","狗");
        map.put("Cat","猫");
        String zhi=input.next();
        if("Dog".equals(zhi)){
            System.out.println(map.get("Dog"));
        }else if("Cat".equals(zhi)){
            System.out.println(map.get("Cat"));
        }else if("猫".equals(zhi)){
            System.out.println("猫");
        }else if("狗".equals(zhi)){
            System.out.println("狗");
        }
    }
}
